﻿using System.Configuration;

namespace MaLu.Config
{
    public static class WebConfig
    {
        public static string DbSetting
        {
            get
            {
                return ConfigurationManager.ConnectionStrings["DbSetting"].ConnectionString;
            }
        }

        public static string ProviderName
        {
            get
            {
                return ConfigurationManager.ConnectionStrings["DbSetting"].ProviderName;
            }
        }

       

        static WebConfig()
        {
            //BlogDbSetting = ConfigurationManager.ConnectionStrings["BlogDbSetting"].ConnectionString;
            //ProviderName = ConfigurationManager.ConnectionStrings["BlogDbSetting"].ProviderName;
            //PasswordKey = ConfigurationManager.AppSettings["PasswordKey"];
            //if (string.IsNullOrEmpty(PasswordKey))
            //    PasswordKey = "levenblog";
            //if (PasswordKey.Length > 8)
            //    PasswordKey = PasswordKey.Substring(0, 8);
            //PrefixKey = ConfigurationManager.AppSettings["PrefixKey"];
            //if (string.IsNullOrEmpty(PrefixKey))
            //    PrefixKey = "levenblog";
            //ExtendName = ConfigurationManager.AppSettings["ExtendName"];
            //if (ExtendName == null)
            //    ExtendName = string.Empty;
            //AdminPasswordKey = ConfigurationManager.AppSettings["AdminPasswordKey"];
            //if (string.IsNullOrEmpty(AdminPasswordKey))
            //    AdminPasswordKey = "uyfs$^%43";
        }
    }
}
